package xcmg.device.dao.entity.materialsSchedule;

import lombok.Data;

import java.math.BigDecimal;
import java.util.Date;

@Data
public class MaterialsScheduleDetailDO {

    /**
     * 0 未出库，1 部分出库，2 已出库
     */
    private static Integer STATUS_NOT_OUT_STOCK = 0;

    private String id;

    private String materialsScheduleId;

    private String materialsNo;

    private String materialsDes;

    private String materialsType;

    private String unit;

    private BigDecimal amount;

    private BigDecimal realAmount;

    private String createId;

    private String createName;

    private Date createDate;

    private String outLocation;

    private String inLocation;

    private Integer status;

    private String note;

    private String stockLocation;

    private String stockUserName;

    private Integer rownum;

    /** 已过账数量*/
    private BigDecimal postAmount;

    private String voucherNo;
    /**领入过账状态  (null/0:未过账，1：部分过账,2:已过账)*/
    private Integer postInStatus;
    /**领出过账状态 (null/0:未过账，1：部分过账,2:已过账)*/
    private Integer postOutStatus;
    /**领入零件凭证*/
    private String voucherInNo;
    /**领入零件凭证*/
    private String voucherOutNo;
    //发货通知单号
    private String deliveryNo;

    /**
     * 是否未出库
     *
     * @return
     */
    public boolean isNotOutStock() {
        return STATUS_NOT_OUT_STOCK.equals(this.status);
    }

}
